package com.gdawj.ejb;

import com.gdawj.javabeans.Aide;
import javax.ejb.Stateless;
import javax.jws.WebService;
import javax.persistence.EntityManager;
import javax.persistence.PersistenceContext;


@WebService
@Stateless
public class AidewsEJB {

    // unite de persistance
    @PersistenceContext(unitName="webcolepu")
    private EntityManager em;

    // ajouter une aide
    public Aide ajouter(Aide aide) {  
        em.persist(aide);
        return aide;
    }
  
}
